<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>直播_龙虾直播</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
     <link rel="stylesheet" href="../themes/jquery.mobile.icons.min.css" />
    <link rel="stylesheet" href="http://wanjia.mcooz.com/views/mobile_basic/skin/default/css/mobile.css" />
    <link rel="stylesheet" href="../themes/orange.min.css" />
  
    <script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/jquery/jquery-1.11.3.min.js"></script><script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/jquery/jquery-migrate-1.2.1.min.js"></script>
    <script src="http://wanjia.mcooz.com/views/mobile_basic/javascript/mobile.js"></script>
    <link rel="stylesheet" href="http://wanjia.mcooz.com/views/mobile_basic/skin/default/css/index.css" />
      <link href="font/css/font-awesome.css" rel="stylesheet">

        <script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/form/form.js"></script>
    <script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/autovalidate/validate.js"></script>
    <link rel="stylesheet" type="text/css" href="http://wanjia.mcooz.com/runtime/_systemjs/autovalidate/style.css" />
     <script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/artTemplate/artTemplate.js"></script><script type="text/javascript" charset="UTF-8" src="http://wanjia.mcooz.com/runtime/_systemjs/artTemplate/artTemplate-plugin.js"></script>
    <script type="text/javascript" src="../script/api.js"></script>      
    <script type="text/javascript" src="../script/main.js"></script>     

</head>

<body>

<div data-role="page" id="Home" data-theme="a">
 
    <div class="container">
<section>
    <div class="pending-detial">
        <div class="panel panel-default">
        <div class="row clearfix bt1">
            <div class="col-md-12 column">
                <h3>
                   <strong id="header">直播</strong>
                </h3>
            </div>
        </div>
        
            <div class="pro_list border-bottom" style="text-align:center;line-height:150px">

            </div>
           
        </div>
    </div>
</section>

</div>
    

  
</div>
</body>
</html>

<script type="text/javascript">
 apiready = function(){
var NVNavigationBar = api.require('NVNavigationBar');
NVNavigationBar.open({
    rect: {
         x: 0,
         y: 0,
         w: api.frameWidth,
         h: 42
    },
   styles: {
         orientation: 'horizontal',
         bg: '#fff',
         bgAlpha: 1,
         font: {
         size: 14,
         sizeSelected: 14,
         color: '#555',
         colorSelected: '#555',
         alpha: 1
         },
         itemSize: {
             w: 90,
             h: 30
         }
   },
    items: [{
       title: '英雄联盟',
       bg: '#FFF',
       bgSelected: 'widget://image/border.png'
       },{
       title: '穿越火线',
       bg: '#FFF',
       bgSelected: 'widget://image/border.png'
       },{
       title: '炉石传说',
       bg: '#FFF',
       bgSelected: 'widget://image/border.png'
       },{
       title: 'dota2',
       bg: '#FFF',
       bgSelected:'widget://image/border.png'
       },{
       title: '王者荣耀',
       bg: '#FFF',
       bgSelected: 'widget://image/border.png'
       },{
       title: '魔兽世界',
       bg: '#FFF',
       bgSelected: 'widget://image/border.png'
       }],
       selectedIndex: 1,
       fixedOn: "frame1",
       id: 'first'
}, function(ret, err) {

  json=JSON.stringify(ret);
    //api.alert({msg:JSON.stringify(ret)});

    //alert(ret.index)

    SwitchBtn(ret.index)

});




funIniGroup1()
api.setFrameGroupAttr({
    name: 'group_',
    hidden: true
});
};

  function SwitchBtn(index) {

         api.setFrameGroupIndex({
            name: 'group_',
            index: index
        });


     }

function funIniGroup1(){
       // var eHeaderLis = $api.domAll('header li'),
       // 
       var winHeight = api.winHeight;
       h=winHeight-$api.dom('#header').offsetHeight-170
            frames = [];
        for (var i = 0,len = 0; i < 6; i++) {
                frames.push( { 
                    name: 'frame_'+i, 
                    url: './frame_'+i+'.html', 
                    bgColor : '#fff',
                    bounces:true,
                     scrollEnabled:false,  
                } )
        }
        api.openFrameGroup({
            name: 'group_',
            scrollEnabled: true,
            rect: {
                x: 0, 
                y: 100, 
                w: api.winWidth, 
                h: h
            },
            index: 0,//定义默认显示的frame
            frames: frames
        }, function (ret, err) {

         // alert( ret.index)
            index=ret.index
            xshowShow(index)

        });
    }

    function xshowShow(index){
      var NVNavigationBar = api.require('NVNavigationBar');
        NVNavigationBar.setSelected({
        id: 'first',
        index: index,
        selected: true
        }, function(ret) {
        //alert(JSON.stringify(ret));
        });
 }

</script>